import 'package:flutter/material.dart';
import 'package:get/get.dart';

import 'logic.dart';

class GetJumpOnePage extends StatelessWidget {
  final GetJumpOneLogic logic = Get.put(GetJumpOneLogic());

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text("跨页面-One"),),
      floatingActionButton: FloatingActionButton(
        onPressed: () => logic.toJumpTwo(),
        child: const Icon(Icons.arrow_forward),
      ),
      body: Center(
        child: GetBuilder<GetJumpOneLogic>(
          builder: (logic) {
            return Text('跨页面-Two点击了${logic.count}次',style: TextStyle(fontSize: 30));
          },
        ),
      ),
    );
  }
}
